1 class (Duration: 1 hour 30 minutes; maximum of 4 students per group).
Circuit Playground Express (CPX), Crickit board, USB cable, 5v Battery
Rain sensor
Inductive proximity sensor
IR sensor
Stepper motor
Jumper wires
Foam board
Cups or containers for sorting bins
Screws, nuts, zip ties and tape for mounting
Basic understanding of sensors and actuators used in earlier lessons
Familiarity with CPX and Crickit boards and basic wiring
Experience assembling simple robotic structures and mounting components
Test the connection and working of various sensors and actuators. Use the reference code given below where needed.
Use this given pseudocode as a reference and implement the code for the garbage sorter.
Test the garbage sorter for various use cases including adding wet waste, dry waste and various other combinations
Use this code to run the garbage sorter. Debug the code to make the garbage sorter work as intended.
If rain sensor, inductive proximity sensor and IR sensor gives values at the same time, how will you decide which action to execute?
Can the CPX and Crickit keep track of how many items have been sorted in each category while the program is running?
What happens to these counts when the board is reset or power is turned off?
If the values are lost after a reset, how could you design the system so the robot remembers this information even after restarting?